package com.koron.css2.electronicCred.Enum;

/**
 * 工程服务枚举类
 *
 * @author 杨嘉慧
 */
public enum ProjectServiceEunm {
    /**
     * 居民用水报装
     */
    CUS_WATER_INSTALLATION("1", "CusWater"),

    /**
     * 企业用水报装
     */
    COMP_WATER_INSTALLATION("5", "CompWater");

    /**
     * 工程类型编号
     */
    private final String projectType;

    /**
     * 服务标识
     */
    private final String serviceMark;

    private ProjectServiceEunm(final String projectType, final String serviceMark) {
        this.projectType = projectType;
        this.serviceMark = serviceMark;
    }

    public static String getServiceMark(String projectType) {
        ProjectServiceEunm[] projectServiceEunms = values();
        for (ProjectServiceEunm projectServiceEunm : projectServiceEunms) {
            if (projectServiceEunm.projectType().equals(projectType)) {
                return projectServiceEunm.serviceMark();
            }
        }
        return null;
    }

    public String projectType() {
        return this.projectType;
    }

    public String serviceMark() {
        return this.serviceMark;
    }
}
